<?php
	/**
	 * This is a MetaControl class, providing a QForm or QPanel access to event handlers
	 * and QControls to perform the Create, Edit, and Delete functionality
	 * of the TableItemGet class.  This code-generated class
	 * contains all the basic elements to help a QPanel or QForm display an HTML form that can
	 * manipulate a single TableItemGet object.
	 *
	 * To take advantage of some (or all) of these control objects, you
	 * must create a new QForm or QPanel which instantiates a TableItemGetMetaControl
	 * class.
	 *
	 * Any and all changes to this file will be overwritten with any subsequent
	 * code re-generation.
	 * 
	 * @package My Application
	 * @subpackage MetaControls
	 * property-read TableItemGet $TableItemGet the actual TableItemGet data class being edited
	 * property QLabel $IdControl
	 * property-read QLabel $IdLabel
	 * property QListBox $UserIdControl
	 * property-read QLabel $UserIdLabel
	 * property QListBox $ItemIdControl
	 * property-read QLabel $ItemIdLabel
	 * property QIntegerTextBox $CurrencyControl
	 * property-read QLabel $CurrencyLabel
	 * property QIntegerTextBox $PointControl
	 * property-read QLabel $PointLabel
	 * property QDateTimePicker $BuyDateControl
	 * property-read QLabel $BuyDateLabel
	 * property QTextBox $ActiveControl
	 * property-read QLabel $ActiveLabel
	 * property QListBox $TransactionIdControl
	 * property-read QLabel $TransactionIdLabel
	 * property-read string $TitleVerb a verb indicating whether or not this is being edited or created
	 * property-read boolean $EditMode a boolean indicating whether or not this is being edited or created
	 */

	class TableItemGetMetaControlGen extends QBaseClass {
		// General Variables
		protected $objTableItemGet;
		protected $objParentObject;
		protected $strTitleVerb;
		protected $blnEditMode;

		// Controls that allow the editing of TableItemGet's individual data fields
		protected $lblId;
		protected $lstUser;
		protected $lstItem;
		protected $txtCurrency;
		protected $txtPoint;
		protected $calBuyDate;
		protected $txtActive;
		protected $lstTransaction;

		// Controls that allow the viewing of TableItemGet's individual data fields
		protected $lblUserId;
		protected $lblItemId;
		protected $lblCurrency;
		protected $lblPoint;
		protected $lblBuyDate;
		protected $lblActive;
		protected $lblTransactionId;

		// QListBox Controls (if applicable) to edit Unique ReverseReferences and ManyToMany References

		// QLabel Controls (if applicable) to view Unique ReverseReferences and ManyToMany References


		/**
		 * Main constructor.  Constructor OR static create methods are designed to be called in either
		 * a parent QPanel or the main QForm when wanting to create a
		 * TableItemGetMetaControl to edit a single TableItemGet object within the
		 * QPanel or QForm.
		 *
		 * This constructor takes in a single TableItemGet object, while any of the static
		 * create methods below can be used to construct based off of individual PK ID(s).
		 *
		 * @param mixed $objParentObject QForm or QPanel which will be using this TableItemGetMetaControl
		 * @param TableItemGet $objTableItemGet new or existing TableItemGet object
		 */
		 public function __construct($objParentObject, TableItemGet $objTableItemGet) {
			// Setup Parent Object (e.g. QForm or QPanel which will be using this TableItemGetMetaControl)
			$this->objParentObject = $objParentObject;

			// Setup linked TableItemGet object
			$this->objTableItemGet = $objTableItemGet;

			// Figure out if we're Editing or Creating New
			if ($this->objTableItemGet->__Restored) {
				$this->strTitleVerb = QApplication::Translate('Edit');
				$this->blnEditMode = true;
			} else {
				$this->strTitleVerb = QApplication::Translate('Create');
				$this->blnEditMode = false;
			}
		 }

		/**
		 * Static Helper Method to Create using PK arguments
		 * You must pass in the PK arguments on an object to load, or leave it blank to create a new one.
		 * If you want to load via QueryString or PathInfo, use the CreateFromQueryString or CreateFromPathInfo
		 * static helper methods.  Finally, specify a CreateType to define whether or not we are only allowed to 
		 * edit, or if we are also allowed to create a new one, etc.
		 * 
		 * @param mixed $objParentObject QForm or QPanel which will be using this TableItemGetMetaControl
		 * @param integer $intId primary key value
		 * @param QMetaControlCreateType $intCreateType rules governing TableItemGet object creation - defaults to CreateOrEdit
 		 * @return TableItemGetMetaControl
		 */
		public static function Create($objParentObject, $intId = null, $intCreateType = QMetaControlCreateType::CreateOrEdit) {
			// Attempt to Load from PK Arguments
			if (strlen($intId)) {
				$objTableItemGet = TableItemGet::Load($intId);

				// TableItemGet was found -- return it!
				if ($objTableItemGet)
					return new TableItemGetMetaControl($objParentObject, $objTableItemGet);

				// If CreateOnRecordNotFound not specified, throw an exception
				else if ($intCreateType != QMetaControlCreateType::CreateOnRecordNotFound)
					throw new QCallerException('Could not find a TableItemGet object with PK arguments: ' . $intId);

			// If EditOnly is specified, throw an exception
			} else if ($intCreateType == QMetaControlCreateType::EditOnly)
				throw new QCallerException('No PK arguments specified');

			// If we are here, then we need to create a new record
			return new TableItemGetMetaControl($objParentObject, new TableItemGet());
		}

		/**
		 * Static Helper Method to Create using PathInfo arguments
		 *
		 * @param mixed $objParentObject QForm or QPanel which will be using this TableItemGetMetaControl
		 * @param QMetaControlCreateType $intCreateType rules governing TableItemGet object creation - defaults to CreateOrEdit
		 * @return TableItemGetMetaControl
		 */
		public static function CreateFromPathInfo($objParentObject, $intCreateType = QMetaControlCreateType::CreateOrEdit) {
			$intId = QApplication::PathInfo(0);
			return TableItemGetMetaControl::Create($objParentObject, $intId, $intCreateType);
		}

		/**
		 * Static Helper Method to Create using QueryString arguments
		 *
		 * @param mixed $objParentObject QForm or QPanel which will be using this TableItemGetMetaControl
		 * @param QMetaControlCreateType $intCreateType rules governing TableItemGet object creation - defaults to CreateOrEdit
		 * @return TableItemGetMetaControl
		 */
		public static function CreateFromQueryString($objParentObject, $intCreateType = QMetaControlCreateType::CreateOrEdit) {
			$intId = QApplication::QueryString('intId');
			return TableItemGetMetaControl::Create($objParentObject, $intId, $intCreateType);
		}



		///////////////////////////////////////////////
		// PUBLIC CREATE and REFRESH METHODS
		///////////////////////////////////////////////

		/**
		 * Create and setup QLabel lblId
		 * @param string $strControlId optional ControlId to use
		 * @return QLabel
		 */
		public function lblId_Create($strControlId = null) {
			$this->lblId = new QLabel($this->objParentObject, $strControlId);
			$this->lblId->Name = QApplication::Translate('Id');
			if ($this->blnEditMode)
				$this->lblId->Text = $this->objTableItemGet->Id;
			else
				$this->lblId->Text = 'N/A';
			return $this->lblId;
		}

		/**
		 * Create and setup QListBox lstUser
		 * @param string $strControlId optional ControlId to use
		 * @return QListBox
		 */
		public function lstUser_Create($strControlId = null) {
			$this->lstUser = new QListBox($this->objParentObject, $strControlId);
			$this->lstUser->Name = QApplication::Translate('User');
			$this->lstUser->Required = true;
			if (!$this->blnEditMode)
				$this->lstUser->AddItem(QApplication::Translate('- Select One -'), null);
			$objUserArray = TableUserProject::LoadAll();
			if ($objUserArray) foreach ($objUserArray as $objUser) {
				$objListItem = new QListItem($objUser->__toString(), $objUser->Id);
				if (($this->objTableItemGet->User) && ($this->objTableItemGet->User->Id == $objUser->Id))
					$objListItem->Selected = true;
				$this->lstUser->AddItem($objListItem);
			}
			return $this->lstUser;
		}

		/**
		 * Create and setup QLabel lblUserId
		 * @param string $strControlId optional ControlId to use
		 * @return QLabel
		 */
		public function lblUserId_Create($strControlId = null) {
			$this->lblUserId = new QLabel($this->objParentObject, $strControlId);
			$this->lblUserId->Name = QApplication::Translate('User');
			$this->lblUserId->Text = ($this->objTableItemGet->User) ? $this->objTableItemGet->User->__toString() : null;
			$this->lblUserId->Required = true;
			return $this->lblUserId;
		}

		/**
		 * Create and setup QListBox lstItem
		 * @param string $strControlId optional ControlId to use
		 * @return QListBox
		 */
		public function lstItem_Create($strControlId = null) {
			$this->lstItem = new QListBox($this->objParentObject, $strControlId);
			$this->lstItem->Name = QApplication::Translate('Item');
			$this->lstItem->Required = true;
			if (!$this->blnEditMode)
				$this->lstItem->AddItem(QApplication::Translate('- Select One -'), null);
			$objItemArray = TableItem::LoadAll();
			if ($objItemArray) foreach ($objItemArray as $objItem) {
				$objListItem = new QListItem($objItem->__toString(), $objItem->Id);
				if (($this->objTableItemGet->Item) && ($this->objTableItemGet->Item->Id == $objItem->Id))
					$objListItem->Selected = true;
				$this->lstItem->AddItem($objListItem);
			}
			return $this->lstItem;
		}

		/**
		 * Create and setup QLabel lblItemId
		 * @param string $strControlId optional ControlId to use
		 * @return QLabel
		 */
		public function lblItemId_Create($strControlId = null) {
			$this->lblItemId = new QLabel($this->objParentObject, $strControlId);
			$this->lblItemId->Name = QApplication::Translate('Item');
			$this->lblItemId->Text = ($this->objTableItemGet->Item) ? $this->objTableItemGet->Item->__toString() : null;
			$this->lblItemId->Required = true;
			return $this->lblItemId;
		}

		/**
		 * Create and setup QIntegerTextBox txtCurrency
		 * @param string $strControlId optional ControlId to use
		 * @return QIntegerTextBox
		 */
		public function txtCurrency_Create($strControlId = null) {
			$this->txtCurrency = new QIntegerTextBox($this->objParentObject, $strControlId);
			$this->txtCurrency->Name = QApplication::Translate('Currency');
			$this->txtCurrency->Text = $this->objTableItemGet->Currency;
			return $this->txtCurrency;
		}

		/**
		 * Create and setup QLabel lblCurrency
		 * @param string $strControlId optional ControlId to use
		 * @param string $strFormat optional sprintf format to use
		 * @return QLabel
		 */
		public function lblCurrency_Create($strControlId = null, $strFormat = null) {
			$this->lblCurrency = new QLabel($this->objParentObject, $strControlId);
			$this->lblCurrency->Name = QApplication::Translate('Currency');
			$this->lblCurrency->Text = $this->objTableItemGet->Currency;
			$this->lblCurrency->Format = $strFormat;
			return $this->lblCurrency;
		}

		/**
		 * Create and setup QIntegerTextBox txtPoint
		 * @param string $strControlId optional ControlId to use
		 * @return QIntegerTextBox
		 */
		public function txtPoint_Create($strControlId = null) {
			$this->txtPoint = new QIntegerTextBox($this->objParentObject, $strControlId);
			$this->txtPoint->Name = QApplication::Translate('Point');
			$this->txtPoint->Text = $this->objTableItemGet->Point;
			$this->txtPoint->Required = true;
			return $this->txtPoint;
		}

		/**
		 * Create and setup QLabel lblPoint
		 * @param string $strControlId optional ControlId to use
		 * @param string $strFormat optional sprintf format to use
		 * @return QLabel
		 */
		public function lblPoint_Create($strControlId = null, $strFormat = null) {
			$this->lblPoint = new QLabel($this->objParentObject, $strControlId);
			$this->lblPoint->Name = QApplication::Translate('Point');
			$this->lblPoint->Text = $this->objTableItemGet->Point;
			$this->lblPoint->Required = true;
			$this->lblPoint->Format = $strFormat;
			return $this->lblPoint;
		}

		/**
		 * Create and setup QDateTimePicker calBuyDate
		 * @param string $strControlId optional ControlId to use
		 * @return QDateTimePicker
		 */
		public function calBuyDate_Create($strControlId = null) {
			$this->calBuyDate = new QDateTimePicker($this->objParentObject, $strControlId);
			$this->calBuyDate->Name = QApplication::Translate('Buy Date');
			$this->calBuyDate->DateTime = $this->objTableItemGet->BuyDate;
			$this->calBuyDate->DateTimePickerType = QDateTimePickerType::DateTime;
			return $this->calBuyDate;
		}

		/**
		 * Create and setup QLabel lblBuyDate
		 * @param string $strControlId optional ControlId to use
		 * @param string $strDateTimeFormat optional DateTimeFormat to use
		 * @return QLabel
		 */
		public function lblBuyDate_Create($strControlId = null, $strDateTimeFormat = null) {
			$this->lblBuyDate = new QLabel($this->objParentObject, $strControlId);
			$this->lblBuyDate->Name = QApplication::Translate('Buy Date');
			$this->strBuyDateDateTimeFormat = $strDateTimeFormat;
			$this->lblBuyDate->Text = sprintf($this->objTableItemGet->BuyDate) ? $this->objTableItemGet->BuyDate->__toString($this->strBuyDateDateTimeFormat) : null;
			return $this->lblBuyDate;
		}

		protected $strBuyDateDateTimeFormat;


		/**
		 * Create and setup QTextBox txtActive
		 * @param string $strControlId optional ControlId to use
		 * @return QTextBox
		 */
		public function txtActive_Create($strControlId = null) {
			$this->txtActive = new QTextBox($this->objParentObject, $strControlId);
			$this->txtActive->Name = QApplication::Translate('Active');
			$this->txtActive->Text = $this->objTableItemGet->Active;
			$this->txtActive->Required = true;
			$this->txtActive->MaxLength = TableItemGet::ActiveMaxLength;
			return $this->txtActive;
		}

		/**
		 * Create and setup QLabel lblActive
		 * @param string $strControlId optional ControlId to use
		 * @return QLabel
		 */
		public function lblActive_Create($strControlId = null) {
			$this->lblActive = new QLabel($this->objParentObject, $strControlId);
			$this->lblActive->Name = QApplication::Translate('Active');
			$this->lblActive->Text = $this->objTableItemGet->Active;
			$this->lblActive->Required = true;
			return $this->lblActive;
		}

		/**
		 * Create and setup QListBox lstTransaction
		 * @param string $strControlId optional ControlId to use
		 * @return QListBox
		 */
		public function lstTransaction_Create($strControlId = null) {
			$this->lstTransaction = new QListBox($this->objParentObject, $strControlId);
			$this->lstTransaction->Name = QApplication::Translate('Transaction');
			$this->lstTransaction->Required = true;
			if (!$this->blnEditMode)
				$this->lstTransaction->AddItem(QApplication::Translate('- Select One -'), null);
			$objTransactionArray = TableTransaction::LoadAll();
			if ($objTransactionArray) foreach ($objTransactionArray as $objTransaction) {
				$objListItem = new QListItem($objTransaction->__toString(), $objTransaction->Id);
				if (($this->objTableItemGet->Transaction) && ($this->objTableItemGet->Transaction->Id == $objTransaction->Id))
					$objListItem->Selected = true;
				$this->lstTransaction->AddItem($objListItem);
			}
			return $this->lstTransaction;
		}

		/**
		 * Create and setup QLabel lblTransactionId
		 * @param string $strControlId optional ControlId to use
		 * @return QLabel
		 */
		public function lblTransactionId_Create($strControlId = null) {
			$this->lblTransactionId = new QLabel($this->objParentObject, $strControlId);
			$this->lblTransactionId->Name = QApplication::Translate('Transaction');
			$this->lblTransactionId->Text = ($this->objTableItemGet->Transaction) ? $this->objTableItemGet->Transaction->__toString() : null;
			$this->lblTransactionId->Required = true;
			return $this->lblTransactionId;
		}



		/**
		 * Refresh this MetaControl with Data from the local TableItemGet object.
		 * @param boolean $blnReload reload TableItemGet from the database
		 * @return void
		 */
		public function Refresh($blnReload = false) {
			if ($blnReload)
				$this->objTableItemGet->Reload();

			if ($this->lblId) if ($this->blnEditMode) $this->lblId->Text = $this->objTableItemGet->Id;

			if ($this->lstUser) {
					$this->lstUser->RemoveAllItems();
				if (!$this->blnEditMode)
					$this->lstUser->AddItem(QApplication::Translate('- Select One -'), null);
				$objUserArray = TableUserProject::LoadAll();
				if ($objUserArray) foreach ($objUserArray as $objUser) {
					$objListItem = new QListItem($objUser->__toString(), $objUser->Id);
					if (($this->objTableItemGet->User) && ($this->objTableItemGet->User->Id == $objUser->Id))
						$objListItem->Selected = true;
					$this->lstUser->AddItem($objListItem);
				}
			}
			if ($this->lblUserId) $this->lblUserId->Text = ($this->objTableItemGet->User) ? $this->objTableItemGet->User->__toString() : null;

			if ($this->lstItem) {
					$this->lstItem->RemoveAllItems();
				if (!$this->blnEditMode)
					$this->lstItem->AddItem(QApplication::Translate('- Select One -'), null);
				$objItemArray = TableItem::LoadAll();
				if ($objItemArray) foreach ($objItemArray as $objItem) {
					$objListItem = new QListItem($objItem->__toString(), $objItem->Id);
					if (($this->objTableItemGet->Item) && ($this->objTableItemGet->Item->Id == $objItem->Id))
						$objListItem->Selected = true;
					$this->lstItem->AddItem($objListItem);
				}
			}
			if ($this->lblItemId) $this->lblItemId->Text = ($this->objTableItemGet->Item) ? $this->objTableItemGet->Item->__toString() : null;

			if ($this->txtCurrency) $this->txtCurrency->Text = $this->objTableItemGet->Currency;
			if ($this->lblCurrency) $this->lblCurrency->Text = $this->objTableItemGet->Currency;

			if ($this->txtPoint) $this->txtPoint->Text = $this->objTableItemGet->Point;
			if ($this->lblPoint) $this->lblPoint->Text = $this->objTableItemGet->Point;

			if ($this->calBuyDate) $this->calBuyDate->DateTime = $this->objTableItemGet->BuyDate;
			if ($this->lblBuyDate) $this->lblBuyDate->Text = sprintf($this->objTableItemGet->BuyDate) ? $this->objTableItemGet->BuyDate->__toString($this->strBuyDateDateTimeFormat) : null;

			if ($this->txtActive) $this->txtActive->Text = $this->objTableItemGet->Active;
			if ($this->lblActive) $this->lblActive->Text = $this->objTableItemGet->Active;

			if ($this->lstTransaction) {
					$this->lstTransaction->RemoveAllItems();
				if (!$this->blnEditMode)
					$this->lstTransaction->AddItem(QApplication::Translate('- Select One -'), null);
				$objTransactionArray = TableTransaction::LoadAll();
				if ($objTransactionArray) foreach ($objTransactionArray as $objTransaction) {
					$objListItem = new QListItem($objTransaction->__toString(), $objTransaction->Id);
					if (($this->objTableItemGet->Transaction) && ($this->objTableItemGet->Transaction->Id == $objTransaction->Id))
						$objListItem->Selected = true;
					$this->lstTransaction->AddItem($objListItem);
				}
			}
			if ($this->lblTransactionId) $this->lblTransactionId->Text = ($this->objTableItemGet->Transaction) ? $this->objTableItemGet->Transaction->__toString() : null;

		}



		///////////////////////////////////////////////
		// PROTECTED UPDATE METHODS for ManyToManyReferences (if any)
		///////////////////////////////////////////////





		///////////////////////////////////////////////
		// PUBLIC TABLEITEMGET OBJECT MANIPULATORS
		///////////////////////////////////////////////

		/**
		 * This will save this object's TableItemGet instance,
		 * updating only the fields which have had a control created for it.
		 */
		public function SaveTableItemGet() {
			try {
				// Update any fields for controls that have been created
				if ($this->lstUser) $this->objTableItemGet->UserId = $this->lstUser->SelectedValue;
				if ($this->lstItem) $this->objTableItemGet->ItemId = $this->lstItem->SelectedValue;
				if ($this->txtCurrency) $this->objTableItemGet->Currency = $this->txtCurrency->Text;
				if ($this->txtPoint) $this->objTableItemGet->Point = $this->txtPoint->Text;
				if ($this->calBuyDate) $this->objTableItemGet->BuyDate = $this->calBuyDate->DateTime;
				if ($this->txtActive) $this->objTableItemGet->Active = $this->txtActive->Text;
				if ($this->lstTransaction) $this->objTableItemGet->TransactionId = $this->lstTransaction->SelectedValue;

				// Update any UniqueReverseReferences (if any) for controls that have been created for it

				// Save the TableItemGet object
				$this->objTableItemGet->Save();

				// Finally, update any ManyToManyReferences (if any)
			} catch (QCallerException $objExc) {
				$objExc->IncrementOffset();
				throw $objExc;
			}
		}

		/**
		 * This will DELETE this object's TableItemGet instance from the database.
		 * It will also unassociate itself from any ManyToManyReferences.
		 */
		public function DeleteTableItemGet() {
			$this->objTableItemGet->Delete();
		}		



		///////////////////////////////////////////////
		// PUBLIC GETTERS and SETTERS
		///////////////////////////////////////////////

		/**
		 * Override method to perform a property "Get"
		 * This will get the value of $strName
		 *
		 * @param string $strName Name of the property to get
		 * @return mixed
		 */
		public function __get($strName) {
			switch ($strName) {
				// General MetaControlVariables
				case 'TableItemGet': return $this->objTableItemGet;
				case 'TitleVerb': return $this->strTitleVerb;
				case 'EditMode': return $this->blnEditMode;

				// Controls that point to TableItemGet fields -- will be created dynamically if not yet created
				case 'IdControl':
					if (!$this->lblId) return $this->lblId_Create();
					return $this->lblId;
				case 'IdLabel':
					if (!$this->lblId) return $this->lblId_Create();
					return $this->lblId;
				case 'UserIdControl':
					if (!$this->lstUser) return $this->lstUser_Create();
					return $this->lstUser;
				case 'UserIdLabel':
					if (!$this->lblUserId) return $this->lblUserId_Create();
					return $this->lblUserId;
				case 'ItemIdControl':
					if (!$this->lstItem) return $this->lstItem_Create();
					return $this->lstItem;
				case 'ItemIdLabel':
					if (!$this->lblItemId) return $this->lblItemId_Create();
					return $this->lblItemId;
				case 'CurrencyControl':
					if (!$this->txtCurrency) return $this->txtCurrency_Create();
					return $this->txtCurrency;
				case 'CurrencyLabel':
					if (!$this->lblCurrency) return $this->lblCurrency_Create();
					return $this->lblCurrency;
				case 'PointControl':
					if (!$this->txtPoint) return $this->txtPoint_Create();
					return $this->txtPoint;
				case 'PointLabel':
					if (!$this->lblPoint) return $this->lblPoint_Create();
					return $this->lblPoint;
				case 'BuyDateControl':
					if (!$this->calBuyDate) return $this->calBuyDate_Create();
					return $this->calBuyDate;
				case 'BuyDateLabel':
					if (!$this->lblBuyDate) return $this->lblBuyDate_Create();
					return $this->lblBuyDate;
				case 'ActiveControl':
					if (!$this->txtActive) return $this->txtActive_Create();
					return $this->txtActive;
				case 'ActiveLabel':
					if (!$this->lblActive) return $this->lblActive_Create();
					return $this->lblActive;
				case 'TransactionIdControl':
					if (!$this->lstTransaction) return $this->lstTransaction_Create();
					return $this->lstTransaction;
				case 'TransactionIdLabel':
					if (!$this->lblTransactionId) return $this->lblTransactionId_Create();
					return $this->lblTransactionId;
				default:
					try {
						return parent::__get($strName);
					} catch (QCallerException $objExc) {
						$objExc->IncrementOffset();
						throw $objExc;
					}
			}
		}

		/**
		 * Override method to perform a property "Set"
		 * This will set the property $strName to be $mixValue
		 *
		 * @param string $strName Name of the property to set
		 * @param string $mixValue New value of the property
		 * @return mixed
		 */
		public function __set($strName, $mixValue) {
			try {
				switch ($strName) {
					// Controls that point to TableItemGet fields
					case 'IdControl':
						return ($this->lblId = QType::Cast($mixValue, 'QControl'));
					case 'UserIdControl':
						return ($this->lstUser = QType::Cast($mixValue, 'QControl'));
					case 'ItemIdControl':
						return ($this->lstItem = QType::Cast($mixValue, 'QControl'));
					case 'CurrencyControl':
						return ($this->txtCurrency = QType::Cast($mixValue, 'QControl'));
					case 'PointControl':
						return ($this->txtPoint = QType::Cast($mixValue, 'QControl'));
					case 'BuyDateControl':
						return ($this->calBuyDate = QType::Cast($mixValue, 'QControl'));
					case 'ActiveControl':
						return ($this->txtActive = QType::Cast($mixValue, 'QControl'));
					case 'TransactionIdControl':
						return ($this->lstTransaction = QType::Cast($mixValue, 'QControl'));
					default:
						return parent::__set($strName, $mixValue);
				}
			} catch (QCallerException $objExc) {
				$objExc->IncrementOffset();
				throw $objExc;
			}
		}
	}
?>